With continuous development of information technologies, more and more terminals begin to support image processing. A terminal may often process an image into an image with blur special effects or tailing special effects. How to simply and rapidly process an image at a terminal so as to achieve blur special effects or tailing special effects is a problem to be considered.
Currently, the Gaussian blur algorithm and accumulation buffer are used so as to achieve the blur special effects and the tailing special effects, respectively. By using the Gaussian blur algorithm, weights are distributed to surrounding pixels of a selected pixel according to normal distribution, an average value of the surrounding pixels of the selected pixel is calculated using weighted averaging and a value of the selected pixel is substituted with the average value obtained through calculation, and all pixels are selected sequentially and a value of each selected pixel is substituted with an average value of surrounding pixels of the selected pixel, thereby achieving image processing of blur special effects. By the accumulation buffer, rendered images are sequentially accumulated to the accumulation buffer to achieve image processing of tailing special effects.
However, by using the Gaussian blur algorithm, it is necessary to sequentially select all pixels, distribute weights to surrounding pixels for each selected pixel, and calculate a weighted average value; the calculation process is complicated; and frequent calling of the Gaussian blur algorithm may slow down the image processing speed. The accumulation buffer technologies are not suitable for Android systems and their use range is small.